from odoo import fields, models, api
import datetime


class opportunityCustomer(models.Model):
    _name = "op.opportunity.customer"
    _description = "商机穿透项目表  表头"
    _rec_name = 'customer'

    # 对应线索客户
    customer = fields.Many2one('res.partner', string='选择对应线索客户')
    amount = fields.Float(string='预估金额')
    score_total = fields.Integer(string='总分数')
    product = fields.Char(string='产品')
    project = fields.One2many(
        comodel_name='op.opportunity.project',
        inverse_name='opportunity_customer',
        string='商机穿透项目',
    )
